from django.shortcuts import render
from rest_framework.response import Response
from rest_framework.views import APIView

from navigation import models, ser


# Create your views here.

class NavigationView(APIView):
    def get(self, request):
        data = models.Navigation.objects.all()
        res = ser.NavigationSerializer(data, many=True)
        return Response({"code": 200, "data": res.data})
